package deleteface.bank.jqsoft.cn.deleteface.base;


import okhttp3.OkHttpClient;
import retrofit2.Retrofit;
import retrofit2.adapter.rxjava.RxJavaCallAdapterFactory;
import retrofit2.converter.fastjson.FastJsonConverterFactory;
import retrofit2.converter.scalars.ScalarsConverterFactory;
import retrofit2.converter.simplexml.SimpleXmlConverterFactory;

public class SignedDoctorClientRetrofit {
//    public static String BASE_URL = Constants.EMPTY_STRING;
//    public static String BASE_URL = BphsConstants.HTTP_PROTOCOL+ BphsConstants.HTTP_TEST_SERVER_IP + ":" + "9093"+ "/fdss-api/";

//    public static String BASE_URL = BphsConstants.Http_Face_erd;
//    public static String BASE_URL = "http://10.1.56.7:5000";
    public static String BASE_URL = "http://10.1.56.7:5000";

//
//public static String BASE_URL="http://10.1.74.58:8080/fdss-api/";
//    铜陵郊区
//    public static String BASE_URL = BphsConstants.HTTP_PROTOCOL
//            + BphsConstants.HTTP_TEST_SERVER_IP + ":" + "9094"+ "/fdss-api/";
//  石台
//    public static String BASE_URL =   BphsConstants.HTTP_PROTOCOL+ "223.240.84.65" + ":" + "9093"+ "/fdss-api/";

    private static Retrofit retrofit;

    public SignedDoctorClientRetrofit(OkHttpClient okHttpClient) {
        http://60.173.37.58:9093/fdss-api/
        retrofit = new Retrofit.Builder()
                .baseUrl(BASE_URL)
                .client(okHttpClient)
                .addCallAdapterFactory(RxJavaCallAdapterFactory.create())
                .addConverterFactory(FastJsonConverterFactory.create())
                .addConverterFactory(SimpleXmlConverterFactory.create())
                .addConverterFactory(ScalarsConverterFactory.create())

                .build();
    }


    public Retrofit getRetrofit() {
        return retrofit;
    }
}
